
<#compress><div class="jqLookupWindow">
	<a href="#" class="jqmClose" onclick="$('#${field_name}_jqm').jqmHide(); return false;">Close</a>
	<div id="${field_name}_searchForm" <#if objects??>class="hidden"</#if>>
		<#if form??>
		<form action='${form_url}?prompt_data=${prompt_data}' method='post'>
		<table>
		${form.asTable()}
		</table>
		<input type="submit">
		</form>
		</#if>
	</div>
	
	<#if objects??>
	<div id="${field_name}_searchResults">
		<a href="#" onclick="$('#${field_name}_searchForm').children('form').ajaxForm({target: '#${field_name}_jqm'}); $('#${field_name}_searchResults').hide(); $('#${field_name}_searchForm').show(); return false;">Search Again</a>
		<div class="pagination">
		    <span class="step-links"><p>
		        <#if objects.hasPrevious >
					<a href="#" onclick="$('#${field_name}_jqm').load('${form_url}?prompt_data=${prompt_data}&page=${objects.previousPageNumber}&${query_string}'); return false;">previous</a>
		        </#if>
		
		        <span class="current">
		            Page ${ objects.number } of ${ objects.paginator.numPages }.
		        </span>
		
		        <#if objects.hasNext >
		            <a href="#" onclick="$('#${field_name}_jqm').load('${form_url}?prompt_data=${prompt_data}&page=${objects.nextPageNumber}&${query_string}'); return false;">next</a>
		        </#if>
		    </p></span>
		</div>
		
		<table>
		  <#list objects.objectList as object>
		    <tr onclick='return $("#${field_name}").jlwUpdate("${StringFormat.format(display, object)?js_string}");'>
		      <#list field_list as field>
		        <#if field_index == 0>
		          <td><a href='#' onclick='return $("#${field_name}").jlwUpdate("${StringFormat.format(display, object)?js_string}");'>${(object[field])!''}</a></td>
		        <#else>
		          <td>${(object[field])!''}</td>
		        </#if>
		      </#list>
		    </tr>
		  </#list>
		 </table>
		 </div>
		</#if>
</div></#compress>